import request from '@/utils/request'

export default {
  // 分页查询
  getUserListPage(page, limit, userQuery) {
    return request({
      url: `/e/user/pageUserCondition/${page}/${limit}`,
      method: 'post',
      data: userQuery
    })
  }, // 通过Id删除
  removeById(id) {
    return request({
      url: `/e/user/removeUser/${id}`,
      method: `delete`
    })
  },
  // 添加讲师
  add(user) {
    return request({
      url: `/e/user/addUser`,
      method: 'post',
      data: user
    })
  },
  // 根据id查询讲师
  getUserInfo(id) {
    return request({
      url: `/e/user/findUserById/${id}`,
      method: 'get'
    })
  },

  updateUserById(express) {
    return request({
      url: `/e/user/updateUserById`,
      method: 'put',
      data: express
    })
  },
  getUserConsole() {
    return request({
      url: `/e/user/console`,
      method: 'get'
    })
  },
  deletes(ids) {
    return request({
      url: `/e/user/deletes`,
      method: 'post',
      data: ids
    })
  }

}
